<?php

/*
 * Action 5$
 *
 * +1 card, +2 Actions, Gain a Spoils from Spoils pile
 */

class BanditCamp extends Card implements iAction, iKingdom, iDarkAges {

    public function __construct() {
        parent::__construct("Bandit Camp", 5);
        $this->undoPlay = false;
        $this->undoBuy = true;
    }

    public function getDescription() {
        return array(
            "+1 card", "+2 actions", "Gain a Spoils from the Spoils pile");
    }

    public function play(Game $game, $isRealCard) {
        $drawed_cards = $game->drawCards(1);
        $game->addActions(2);
        ScreenDisplay::addScreenMessage($game, true, " get 2 actions, draw " . nicePrint($drawed_cards), " gets 2 actions, draws  " . sizeof($drawed_cards) . " cards");

        $card = $game->moveCardFromPileToPile(null, Spoils, DiscardPile);
        ScreenDisplay::addScreenMessage($game, false, " and gain " . nicePrint($card), " and gains " . ScreenDisplay::$LMSG);
        $game->cardActionFinished();
        return true;
    }

    public function boardSetup(Game $game) {
        $game->addSpoils();
        return true;
    }

}

?>